new Vue({
  el: '#app',
  data(){
    return {
      showLogin: false,
      showRegister: false,
      list: [],
      labels: ["宠物","运动","帮手","城游"]
    }
  },
  mounted(){
    this.getList(null)
  },
  methods:{
    async getList(labelId){
      const params = labelId ? { labelId } : {}
      const res = await request('/web/getList', 'post', params);
      this.list = res.data
    },
    clickLabelHandle(i){
      this.getList(i+1)
    }
  }
})